<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
        "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:h="http://java.sun.com/jsf/html"
      xmlns:f="http://java.sun.com/jsf/core"
      xmlns:ui="http://java.sun.com/jsf/facelets"
      xmlns:p="http://primefaces.org/ui"
      lang="#{localeController.language}">

<f:view locale="#{localeController.locale}" encoding="UTF-8" contentType="text/html">
    <h:head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
        <title><ui:insert name="title">#{msg.defaultTitle}</ui:insert></title>
    </h:head>
    <h:body>
        <p:ajaxStatus>
            <f:facet name="start">
                <p:outputPanel styleClass="ajaxStatus">
                    #{msg.processing}
                </p:outputPanel>
            </f:facet>
            <f:facet name="complete">
                <h:outputText value=""/>
            </f:facet>
        </p:ajaxStatus>
        <h:outputScript library="js" name="primefaces.js" target="body"/>
        <h:outputStylesheet library="css" name="style.css"/>
        <p:layout fullPage="true">
            <p:layoutUnit position="north" size="76" resizable="false" closable="false" collapsible="false"
                          style="padding:1px">
                <h:panelGrid columns="3" cellpadding="0" style="width:100%; border-spacing: 0">
                    <img src="#{resource[ 'img:logo.jpg' ]}" width="220" height="66" alt="Logo ISS"
                         style="margin:0; padding:0"/>
                    <h:panelGroup>
                        <h2><ui:insert name="heading">#{msg.defaultTitle}</ui:insert></h2>
                    </h:panelGroup>
                    <h:panelGroup style="float: right;">
                        <ui:insert name="status"><ui:include src="../templates/tiles/status.xhtml"/></ui:insert>
                    </h:panelGroup>
                </h:panelGrid>
            </p:layoutUnit>

            <p:layoutUnit position="south" size="60" resizable="true" closable="true"
                          collapsible="true" styleClass="textCenter">
                <h:outputText value="#{msg.defaultFooterTitle}"/>
            </p:layoutUnit>

            <p:layoutUnit position="west" size="200" header="Menú" resizable="true" closable="false"
                          collapsible="false">
                <ui:include src="../templates/tiles/leftMenu.xhtml"/>
            </p:layoutUnit>

            <p:layoutUnit position="center">
                <ui:insert name="content">Put default content here, if any.</ui:insert>
            </p:layoutUnit>
        </p:layout>
    </h:body>
</f:view>
</html>